/**
 * 封装图表请求数据
 */

import req from '@/utils/request'

/** ------------------------------1.首页报表请求------------------------------------ */
export function getTotalData() {
  return req.get('/order/totaldata')
}
/** ------------------------------2.订单统计报表请求------------------------------------ */
/**
 *
 * @param {String} params date ["2019-10-01 00:00:00", "2019-10-10 00:00:00"]
 */
export function getOrderTotal(params) {
  return req.get('/order/ordertotal', params)
}

/** ------------------------------3.获取订单列表------------------------------------ */
export function getOrderList(params) {
  return req.get('/order/list', params)
}
/** ------------------------------4.修改订单------------------------------------ */
export function editOrder(params) {
  return req.post('/order/edit', params)
}
/** ------------------------------5.获取订单详情------------------------------------ */
export function getOrderDetail(params) {
  return req.get('/order/detail', params)
}
